View Issue Details
| ID | Project | Category | View Status | Date Submitted | Last Update |
|---|---|---|---|---|---|
| 0001328 | K18X001.00 SKB SWAN | SW | public | 2021-08-24 16:53 | 2021-09-28 10:17 |
| Reporter | (ALTech) Sangmin Choi | Assigned To | (ALTech) Sangmin Choi | Due Date | 2021-08-26 17:39 |
| Priority | urgent | Severity | s2-severe | Reproducibility | always |
| Status | closed | Resolution | fixed | ||
| Summary | 0001328: There is a noise during NUGU audio play. | ||||
| Description | There is a noise during NUGU audio play. ("Aria" -> "Say something like ask weather" -> You can see the TTS play with noise") When I set the audio option as "B tv", I can hear the noise. And, when I set the audio option as "External device", I can't hear the noise. But, there was no issue until 20210727 daily build. After upgrade 20210728, this issue was happened. I guess it's related with Karaoke function, I can see many commits related with Karaoke on 20210728 daily build. The A113X firmware version is 0x21. Could you please check this issue ASAP? | ||||
| Tags | No tags attached. | ||||
| Attach Tags | |||||
| related to | 0001331 | closed | (ALTech) Lonnie Kim | [SWAN]Audio drop issue during NUGU operating |
|
|
Hi Sita and River, Please check the commits in 20210728 and find which commit cause the noise and have solution on it. |
|
|
Hi Wooshin, Let me correct the description. Current not any daily build has no problem with NUGU noise when under UHD or multiview. It is the same issue as Synaptics Jira 165. As Kail said that the issue is reproduced under UHD and multiview. I guess the UHD is for IPTV. Because Youtube 4K content will be paused when using RCU NUGU. Could you provide the UHD content(channel 73) for IPTV that can reproduce this issue? So, we can try to help to analyze the issue. |
|
|
Hi Wooshin, We had a discussion with Synatpics on Synatpics Jira 165 about the NUGU noise issue. I follow Synpatics's suggestion to change some code in vendor/synaptics/btv-hal-impl/synaptics/hal_av_pipeline.c I test the modified code with Ch73 stream file(4K/AAC), it seems the result is good. Could you help to test the following image to see if NUGU issue is fixed or not when playing multiview or UHD? http://altserver01.iptime.org/release_by_fxn/swan_test_image/20210906_NuguNoiseFix/ If the image can fix the issue, please also try to give the following patch to SPtek to review. Because I found SPtek always change code on this file (I think it is because Sptek is responsed for IPTV Player). I am not sure the modified code for case "if (PREPARE_PASSTHROUGH)" is right or not. hal_av_pipeline.c.patch (4,867 bytes)
diff --git a/hal_av_pipeline.c b/hal_av_pipeline.c
index 26dd709..cb2872f 100644
--- a/hal_av_pipeline.c
+++ b/hal_av_pipeline.c
@@ -192,10 +192,10 @@ int AVP_Stop(AVP_HANDLE player) {
assert(ret == SUCCESS);
amp_zapping_mgr_stop_service(player);
-
- if( !socPlayerInfo->playerConfig.keep_last_frame ) {
- AMP_RPC(ret, AMP_DISP_Push_BuildInFrame, socPlayerInfo->amp_disp, socPlayerInfo->pip ? 1:0, 0);
- }
+
+ if( !socPlayerInfo->playerConfig.keep_last_frame ) {
+ AMP_RPC(ret, AMP_DISP_Push_BuildInFrame, socPlayerInfo->amp_disp, socPlayerInfo->pip ? 1:0, 0);
+ }
#ifdef AMP_LOG_WRITE_FILE
if(logFp[socPlayerInfo->pip ? 1:0] != NULL)
@@ -493,7 +493,7 @@ int AVP_SetAudioMute(AVP_HANDLE player, bool mute) {
if(oldMuteState != mute) {
//HRESULT ret = AMP_SND_SetMute(AMP_SND_PATH_71, ismute ? TRUE:FALSE);
//AMP_SND_SetMute(AMP_SND_PATH_HDMI, ismute ? TRUE:FALSE); //HDMI mute
-
+ /*
ret = AMP_SND_SetStreamMute((HANDLE)socPlayerInfo->amp_tunnel, mute ? TRUE:FALSE);
if (SUCCESS == ret) {
ALOGD("++%s[%d] %s audio\n", __FUNCTION__, socPlayerInfo->pip, mute ? "mute" : "unmute");
@@ -507,6 +507,55 @@ int AVP_SetAudioMute(AVP_HANDLE player, bool mute) {
ret = AMP_SND_SetStreamMute((HANDLE)socPlayerInfo->amp_tunnel3, mute ? TRUE:FALSE);
//assert(ret == SUCCESS);
}
+ */
+ //Vas modified start; For fix NUGU TTS noise when play 4K content and multivie; River 2021/09/02
+ if(mute){
+ ret = AMP_SND_SetStreamMute((HANDLE)socPlayerInfo->amp_tunnel, mute ? TRUE:FALSE);
+ if (SUCCESS == ret) {
+ ALOGD("++%s[%d] %s audio\n", __FUNCTION__, socPlayerInfo->pip, mute ? "mute" : "unmute");
+ } else ALOGD("++%s[%d] failed to call AMP_SND_SetMute, r = 0x%x", __FUNCTION__, socPlayerInfo->pip, ret);
+
+ if (PREPARE_PASSTHROUGH) {
+ ret = AMP_SND_SetStreamMute((HANDLE)socPlayerInfo->amp_tunnel2, mute ? TRUE:FALSE);
+ //assert(ret == SUCCESS);
+ ret = AMP_SND_SetStreamMute((HANDLE)socPlayerInfo->amp_tunnel3, mute ? TRUE:FALSE);
+ //assert(ret == SUCCESS);
+ }
+
+ ALOGE("AMP_CLK_SetAVSyncOption set AMP_CLK_DROP");
+ AMP_RPC(ret, AMP_CLK_SetAVSyncOption, socPlayerInfo->amp_clk, 1, AMP_CLK_OPT_SYNC_OVERWRITE, 1, AMP_CLK_DROP, 0);
+ if (SUCCESS != ret) { ALOGE("++%s[%d] failed to call AMP_CLK_SetAVSyncOption 1 for mute, r = 0x%x", __FUNCTION__, socPlayerInfo->pip, ret); }
+ if (PREPARE_PASSTHROUGH) {
+ AMP_RPC(ret, AMP_CLK_SetAVSyncOption, socPlayerInfo->amp_clk, 2, AMP_CLK_OPT_SYNC_OVERWRITE, 1, AMP_CLK_DROP, 0);
+ if (SUCCESS != ret) { ALOGE("++%s[%d] failed to call AMP_CLK_SetAVSyncOption 2 for mute, r = 0x%x", __FUNCTION__, socPlayerInfo->pip, ret); }
+ AMP_RPC(ret, AMP_CLK_SetAVSyncOption, socPlayerInfo->amp_clk, 3, AMP_CLK_OPT_SYNC_OVERWRITE, 1, AMP_CLK_DROP, 0);
+ if (SUCCESS != ret) { ALOGE("++%s[%d] failed to call AMP_CLK_SetAVSyncOption 3 for mute, r = 0x%x", __FUNCTION__, socPlayerInfo->pip, ret); }
+ }
+ }
+ else{
+ ALOGE("AMP_CLK_SetAVSyncOption unset AMP_CLK_DROP");
+ AMP_RPC(ret, AMP_CLK_SetAVSyncOption, socPlayerInfo->amp_clk, 1, AMP_CLK_OPT_SYNC_OVERWRITE, 0, AMP_CLK_DROP, 0);
+ if (SUCCESS != ret) { ALOGE("++%s[%d] failed to call AMP_CLK_SetAVSyncOption 1 for unmute, r = 0x%x", __FUNCTION__, socPlayerInfo->pip, ret); }
+ if (PREPARE_PASSTHROUGH) {
+ AMP_RPC(ret, AMP_CLK_SetAVSyncOption, socPlayerInfo->amp_clk, 2, AMP_CLK_OPT_SYNC_OVERWRITE, 0, AMP_CLK_DROP, 0);
+ if (SUCCESS != ret) { ALOGE("++%s[%d] failed to call AMP_CLK_SetAVSyncOption 2 for unmute, r = 0x%x", __FUNCTION__, socPlayerInfo->pip, ret); }
+ AMP_RPC(ret, AMP_CLK_SetAVSyncOption, socPlayerInfo->amp_clk, 3, AMP_CLK_OPT_SYNC_OVERWRITE, 0, AMP_CLK_DROP, 0);
+ if (SUCCESS != ret) { ALOGE("++%s[%d] failed to call AMP_CLK_SetAVSyncOption 3 for unmute, r = 0x%x", __FUNCTION__, socPlayerInfo->pip, ret); }
+ }
+
+ ret = AMP_SND_SetStreamMute((HANDLE)socPlayerInfo->amp_tunnel, mute ? TRUE:FALSE);
+ if (SUCCESS == ret) {
+ ALOGD("++%s[%d] %s audio\n", __FUNCTION__, socPlayerInfo->pip, mute ? "mute" : "unmute");
+ } else ALOGD("++%s[%d] failed to call AMP_SND_SetMute, r = 0x%x", __FUNCTION__, socPlayerInfo->pip, ret);
+
+ if (PREPARE_PASSTHROUGH) {
+ ret = AMP_SND_SetStreamMute((HANDLE)socPlayerInfo->amp_tunnel2, mute ? TRUE:FALSE);
+ //assert(ret == SUCCESS);
+ ret = AMP_SND_SetStreamMute((HANDLE)socPlayerInfo->amp_tunnel3, mute ? TRUE:FALSE);
+ //assert(ret == SUCCESS);
+ }
+ }
+ //Vas modified end; River 2021/09/02
} else ALOGD("++%s[%d] already is mute %s", __FUNCTION__, socPlayerInfo->pip, mute ? "enable" : "disable");
} else ALOGD("++%s[%d] failed to call AMP_SND_GetMute, r = 0x%x", __FUNCTION__, socPlayerInfo->pip, ret);
|
|
|
Hi Wooshin, Because you said you still can hear NUGU TTS noise. could you help to get the audio dump when you hear NUGU TTS noise? The step to enable audio dump: 1.Use the following commands to lower the volume to avoid too loud audio: su i2cset -f -y 0 0x2a 0x17 0x70 b i2cset -f -y 0 0x2b 0x17 0x70 b i2cset -f -y 0 0x2c 0x17 0x70 b i2cset -f -y 0 0x2d 0x17 0x70 b i2cset -f -y 0 0x2a 0x18 0x70 b i2cset -f -y 0 0x2b 0x18 0x70 b i2cset -f -y 0 0x2c 0x18 0x70 b i2cset -f -y 0 0x2d 0x18 0x70 b i2cdump -f -y 0 0x2a 2. Adjust BTV UI Volume to 25 and NUGU UI Volume to 27. 3. Enable audio dump by following commands: setenforce 0 ampclient_alpha 28 -am 1 4. Try to reproduce NUGU TTS noise. 5. After you hear NUGU TTS noise, please pull a /data/AoutMultiIn0-xxx.bin file to me (xxx is a random number). I can check if there is any NUGU TTS noise. |
|
|
Please checked attached file. |
|
|
Hi Wooshin, From the AoutMultiIn0-3344.bin, I did not see any audio gap in NUGU TTS. You can try to use audacity to import the file to play it again. (File->Import->Raw Data, Select Aout.bin file and refer to the following jpg for the import options) . I think maybe you can try to ask SKT to modify to only play a 1kHz sine tone as NUGU TTS audio (no matter ask any question in NUGU), Then it will be easy to check it. |
|
|
Hi river, 1. Start Record 2. Stop recording when i hear an unnatural sound or noise 3. If i listen to the recorded data on a PC, i can hear it clearly |
|
|
Hi Wooshin, Synaptics asks to enlarge audiohal push buffer . I build a test image in http://altserver01.iptime.org/release_by_fxn/swan_test_image/20210906_NuguEnlargePushThr Please try it. |
|
|
Hi Wooshin, The Nugu TTS noise fixes has two patches. But I did not have permission to commit code into vendor/synaptics/btv-hal-impl/synaptics. I attached one of the NUGU noise fix patch. Please have SPtek or Synpatics Tony to commit it. 0001-Fix-NUGU-TTS-noise-when-UHD-or-multiview-is-playing.patch (5,244 bytes)
From 19dd4d9c43fcd2bfc1440e40ad641cc498d0ad02 Mon Sep 17 00:00:00 2001
From: river wong <river.wong@fii-foxconn.com>
Date: Tue, 7 Sep 2021 15:05:35 +0800
Subject: [PATCH] Fix NUGU TTS noise when UHD or multiview is playing. [1/2]
---
hal_av_pipeline.c | 59 ++++++++++++++++++++++++++++++++++++++++++++++++++-----
1 file changed, 54 insertions(+), 5 deletions(-)
diff --git a/hal_av_pipeline.c b/hal_av_pipeline.c
index 26dd709..cb2872f 100644
--- a/hal_av_pipeline.c
+++ b/hal_av_pipeline.c
@@ -192,10 +192,10 @@ int AVP_Stop(AVP_HANDLE player) {
assert(ret == SUCCESS);
amp_zapping_mgr_stop_service(player);
-
- if( !socPlayerInfo->playerConfig.keep_last_frame ) {
- AMP_RPC(ret, AMP_DISP_Push_BuildInFrame, socPlayerInfo->amp_disp, socPlayerInfo->pip ? 1:0, 0);
- }
+
+ if( !socPlayerInfo->playerConfig.keep_last_frame ) {
+ AMP_RPC(ret, AMP_DISP_Push_BuildInFrame, socPlayerInfo->amp_disp, socPlayerInfo->pip ? 1:0, 0);
+ }
#ifdef AMP_LOG_WRITE_FILE
if(logFp[socPlayerInfo->pip ? 1:0] != NULL)
@@ -493,7 +493,7 @@ int AVP_SetAudioMute(AVP_HANDLE player, bool mute) {
if(oldMuteState != mute) {
//HRESULT ret = AMP_SND_SetMute(AMP_SND_PATH_71, ismute ? TRUE:FALSE);
//AMP_SND_SetMute(AMP_SND_PATH_HDMI, ismute ? TRUE:FALSE); //HDMI mute
-
+ /*
ret = AMP_SND_SetStreamMute((HANDLE)socPlayerInfo->amp_tunnel, mute ? TRUE:FALSE);
if (SUCCESS == ret) {
ALOGD("++%s[%d] %s audio\n", __FUNCTION__, socPlayerInfo->pip, mute ? "mute" : "unmute");
@@ -507,6 +507,55 @@ int AVP_SetAudioMute(AVP_HANDLE player, bool mute) {
ret = AMP_SND_SetStreamMute((HANDLE)socPlayerInfo->amp_tunnel3, mute ? TRUE:FALSE);
//assert(ret == SUCCESS);
}
+ */
+ //Vas modified start; For fix NUGU TTS noise when play 4K content and multivie; River 2021/09/02
+ if(mute){
+ ret = AMP_SND_SetStreamMute((HANDLE)socPlayerInfo->amp_tunnel, mute ? TRUE:FALSE);
+ if (SUCCESS == ret) {
+ ALOGD("++%s[%d] %s audio\n", __FUNCTION__, socPlayerInfo->pip, mute ? "mute" : "unmute");
+ } else ALOGD("++%s[%d] failed to call AMP_SND_SetMute, r = 0x%x", __FUNCTION__, socPlayerInfo->pip, ret);
+
+ if (PREPARE_PASSTHROUGH) {
+ ret = AMP_SND_SetStreamMute((HANDLE)socPlayerInfo->amp_tunnel2, mute ? TRUE:FALSE);
+ //assert(ret == SUCCESS);
+ ret = AMP_SND_SetStreamMute((HANDLE)socPlayerInfo->amp_tunnel3, mute ? TRUE:FALSE);
+ //assert(ret == SUCCESS);
+ }
+
+ ALOGE("AMP_CLK_SetAVSyncOption set AMP_CLK_DROP");
+ AMP_RPC(ret, AMP_CLK_SetAVSyncOption, socPlayerInfo->amp_clk, 1, AMP_CLK_OPT_SYNC_OVERWRITE, 1, AMP_CLK_DROP, 0);
+ if (SUCCESS != ret) { ALOGE("++%s[%d] failed to call AMP_CLK_SetAVSyncOption 1 for mute, r = 0x%x", __FUNCTION__, socPlayerInfo->pip, ret); }
+ if (PREPARE_PASSTHROUGH) {
+ AMP_RPC(ret, AMP_CLK_SetAVSyncOption, socPlayerInfo->amp_clk, 2, AMP_CLK_OPT_SYNC_OVERWRITE, 1, AMP_CLK_DROP, 0);
+ if (SUCCESS != ret) { ALOGE("++%s[%d] failed to call AMP_CLK_SetAVSyncOption 2 for mute, r = 0x%x", __FUNCTION__, socPlayerInfo->pip, ret); }
+ AMP_RPC(ret, AMP_CLK_SetAVSyncOption, socPlayerInfo->amp_clk, 3, AMP_CLK_OPT_SYNC_OVERWRITE, 1, AMP_CLK_DROP, 0);
+ if (SUCCESS != ret) { ALOGE("++%s[%d] failed to call AMP_CLK_SetAVSyncOption 3 for mute, r = 0x%x", __FUNCTION__, socPlayerInfo->pip, ret); }
+ }
+ }
+ else{
+ ALOGE("AMP_CLK_SetAVSyncOption unset AMP_CLK_DROP");
+ AMP_RPC(ret, AMP_CLK_SetAVSyncOption, socPlayerInfo->amp_clk, 1, AMP_CLK_OPT_SYNC_OVERWRITE, 0, AMP_CLK_DROP, 0);
+ if (SUCCESS != ret) { ALOGE("++%s[%d] failed to call AMP_CLK_SetAVSyncOption 1 for unmute, r = 0x%x", __FUNCTION__, socPlayerInfo->pip, ret); }
+ if (PREPARE_PASSTHROUGH) {
+ AMP_RPC(ret, AMP_CLK_SetAVSyncOption, socPlayerInfo->amp_clk, 2, AMP_CLK_OPT_SYNC_OVERWRITE, 0, AMP_CLK_DROP, 0);
+ if (SUCCESS != ret) { ALOGE("++%s[%d] failed to call AMP_CLK_SetAVSyncOption 2 for unmute, r = 0x%x", __FUNCTION__, socPlayerInfo->pip, ret); }
+ AMP_RPC(ret, AMP_CLK_SetAVSyncOption, socPlayerInfo->amp_clk, 3, AMP_CLK_OPT_SYNC_OVERWRITE, 0, AMP_CLK_DROP, 0);
+ if (SUCCESS != ret) { ALOGE("++%s[%d] failed to call AMP_CLK_SetAVSyncOption 3 for unmute, r = 0x%x", __FUNCTION__, socPlayerInfo->pip, ret); }
+ }
+
+ ret = AMP_SND_SetStreamMute((HANDLE)socPlayerInfo->amp_tunnel, mute ? TRUE:FALSE);
+ if (SUCCESS == ret) {
+ ALOGD("++%s[%d] %s audio\n", __FUNCTION__, socPlayerInfo->pip, mute ? "mute" : "unmute");
+ } else ALOGD("++%s[%d] failed to call AMP_SND_SetMute, r = 0x%x", __FUNCTION__, socPlayerInfo->pip, ret);
+
+ if (PREPARE_PASSTHROUGH) {
+ ret = AMP_SND_SetStreamMute((HANDLE)socPlayerInfo->amp_tunnel2, mute ? TRUE:FALSE);
+ //assert(ret == SUCCESS);
+ ret = AMP_SND_SetStreamMute((HANDLE)socPlayerInfo->amp_tunnel3, mute ? TRUE:FALSE);
+ //assert(ret == SUCCESS);
+ }
+ }
+ //Vas modified end; River 2021/09/02
} else ALOGD("++%s[%d] already is mute %s", __FUNCTION__, socPlayerInfo->pip, mute ? "enable" : "disable");
} else ALOGD("++%s[%d] failed to call AMP_SND_GetMute, r = 0x%x", __FUNCTION__, socPlayerInfo->pip, ret);
--
2.7.4
|
|
|
Synpatics patches are commited on 9/7. |
|
|
Update: Since there is a side effect that play VOD will have audio delay 3~4 seconds after NUGU TTS end. Remove the patch in vendor/synaptics/btv-hal-impl/synaptics (0001-Fix-NUGU-TTS-noise-when-UHD-or-multiview-is-playing.patch) can avoid this and also no NUGU TTS noise. |
| Date Modified | Username | Field | Change |
|---|---|---|---|
| 2021-08-24 16:53 | (ALTech) Sangmin Choi | New Issue | |
| 2021-08-24 16:53 | (ALTech) Sangmin Choi | Status | new => assigned |
| 2021-08-24 16:53 | (ALTech) Sangmin Choi | Assigned To | => (SW) Jacky Chiang |
| 2021-08-24 17:16 | (SW) Jacky Chiang | Assigned To | (SW) Jacky Chiang => (SW) Sita Huang |
| 2021-08-24 17:18 | (SW) Jacky Chiang | Note Added: 0007955 | |
| 2021-08-27 12:41 | (SW) Jacky Chiang | Relationship added | related to 0001331 |
| 2021-08-27 12:41 | (SW) Jacky Chiang | Assigned To | (SW) Sita Huang => (SW) Dean Chiang |
| 2021-09-01 14:44 |
|
Note Added: 0008032 | |
| 2021-09-02 08:33 | (SW) Jacky Chiang | Assigned To | (SW) Dean Chiang => (SW) River Wong |
| 2021-09-06 15:01 |
|
File Added: hal_av_pipeline.c.patch | |
| 2021-09-06 15:01 |
|
Note Added: 0008078 | |
| 2021-09-06 16:09 |
|
Note Added: 0008079 | |
| 2021-09-06 16:21 | (ALTech) Wooshin Kang | File Added: AoutMultiIn0-3344.bin | |
| 2021-09-06 16:21 | (ALTech) Wooshin Kang | Note Added: 0008080 | |
| 2021-09-06 16:51 |
|
File Added: audacity_how_to_import_Aout.jpg | |
| 2021-09-06 16:51 |
|
Note Added: 0008081 | |
| 2021-09-06 18:14 | (ALTech) Wooshin Kang | Note Added: 0008083 | |
| 2021-09-06 19:05 |
|
Note Added: 0008084 | |
| 2021-09-07 15:14 |
|
File Added: 0001-Fix-NUGU-TTS-noise-when-UHD-or-multiview-is-playing.patch | |
| 2021-09-07 15:14 |
|
Note Added: 0008097 | |
| 2021-09-07 17:53 |
|
Status | assigned => resolved |
| 2021-09-07 17:53 |
|
Resolution | open => fixed |
| 2021-09-07 17:53 |
|
Note Added: 0008101 | |
| 2021-09-07 17:54 |
|
Assigned To | (SW) River Wong => (ALTech) Sangmin Choi |
| 2021-09-09 14:26 |
|
Note Added: 0008140 | |
| 2021-09-28 10:17 | (ALTech) Wooshin Kang | Status | resolved => closed |
